/// <reference path="../../wx/device/WxDevice.ts" />
namespace mplat {
    export class OppoDevice extends WxDevice {

        setClipboardData(data: any, success?: () => void): void {
            if (!qg['setClipboardData']) return;
            qg.setClipboardData({
                data,
                success
            } as _setClipboardDataObject)
        }
        getClipboardData(success: (res: any) => void): void {
            if (!qg['getClipboardData']) return;
            qg['getClipboardData']({
                success
            } as _getClipboardDataObject)
        }

        vibrateLong(): void {
            if (!this._isVibrateOn) return;
            if (qg['vibrateLong']) {
                qg['vibrateLong']({} as _vibrateLongObject);
            }
        }
        vibrateShort(): void {
            if (!this._isVibrateOn) return;
            if (qg['vibrateShort']) {
                qg['vibrateShort']({} as _vibrateShortObject);
            }
        }

        setKeepScreenOn(keepScreenOn: boolean): void {
            if (qg["setKeepScreenOn"]) {
                qg["setKeepScreenOn"]({ keepScreenOn } as _setKeepScreenOnObject);
            }
        }
    }
}